/* 患者案例页面样式 */
.cases-page {
  height: 100vh;
  background-color: #000;
  overflow: hidden;
}



/* 分类标签样式 */
.category-tabs {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 999;
  display: flex;
  background: transparent;
  padding: 8px 16px;
  overflow-x: auto;
  white-space: nowrap;
}

.category-tab {
  padding: 6px 16px;
  margin-right: 12px;
  border-radius: 20px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.category-tab.active {
  color: #fff;
  background: #ff6b6b;
  box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
}

.category-tab:hover {
  background: rgba(0, 0, 0, 0.5);
  transform: translateY(-1px);
}

/* 视频容器样式 */
.video-container {
  height: 100vh;
  overflow: hidden;
  position: relative;
  margin-top: 0; /* 不占用空间 */
  cursor: grab;
}

.video-container:active {
  cursor: grabbing;
}

.video-wrapper {
  height: 100%;
  transition: transform 0.3s ease;
}

.video-item {
  height: 100vh;
  position: relative;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 视频播放器样式 */
.video-player {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000;
  cursor: pointer;
}

/* 视频加载覆盖层 */
.video-loading-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  z-index: 5;
}

.video-loading-overlay p {
  margin-top: 16px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
}

/* 视频错误覆盖层 */
.video-error-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.9);
  color: #fff;
  z-index: 5;
}

.error-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.7;
}

.video-error-overlay p {
  margin: 0 0 20px 0;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
}

.retry-button {
  background: #ff6b6b;
  color: #fff;
  border: none;
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.retry-button:hover {
  background: #ff5252;
  transform: scale(1.05);
}

/* 视频覆盖层样式 */
.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.3) 0%,
    transparent 30%,
    transparent 70%,
    rgba(0, 0, 0, 0.3) 100%
  );
}

/* 右侧操作按钮 */
.video-actions-right {
  position: absolute;
  right: 20px;
  bottom: 120px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  z-index: 10;
}

.action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.action-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.action-icon svg {
  font-size: 24px;
  color: #fff;
  transition: all 0.3s ease;
}

.action-icon svg.active {
  color: #ff6b6b;
  transform: scale(1.1);
}

.action-text {
  font-size: 12px;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

/* 左侧视频信息 */
.video-info {
  position: absolute;
  left: 20px;
  bottom: 120px;
  max-width: 60%;
  z-index: 10;
}

.video-title {
  font-size: 18px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 8px 0;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  line-height: 1.4;
}

.video-abstract {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 0 12px 0;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.video-meta {
  display: flex;
  gap: 12px;
  align-items: center;
}

.video-duration,
.video-price,
.video-buys {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
  background: rgba(0, 0, 0, 0.3);
  padding: 4px 8px;
  border-radius: 12px;
  backdrop-filter: blur(10px);
}

.video-price {
  color: #ffd700;
  font-weight: 500;
}

/* 底部进度指示器 */
.video-progress {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.progress-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
}

.progress-dot.active {
  background: #fff;
  transform: scale(1.2);
}

/* 播放按钮 */
.play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: #fff;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.play-button:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%) scale(1.1);
}

/* 加载状态 */
.cases-loading {
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #000;
  color: #fff;
}

.cases-loading p {
  margin-top: 16px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
}

/* 空状态 */
.video-empty {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  color: #fff;
}

.video-empty p {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.7);
}

/* 响应式设计 */
@media (max-width: 375px) {
  .video-container {
    margin-top: 0;
  }
  
  .category-tabs {
    top: 0;
    padding: 6px 12px;
  }
  
  .video-overlay {
    padding: 16px;
  }
  
  .video-actions-right {
    right: 16px;
    bottom: 100px;
  }
  
  .video-info {
    left: 16px;
    bottom: 100px;
    max-width: 65%;
  }
  
  .video-title {
    font-size: 16px;
  }
  
  .video-abstract {
    font-size: 13px;
  }
  
  .action-icon {
    width: 40px;
    height: 40px;
  }
  
  .action-icon svg {
    font-size: 20px;
  }
}

/* 深色模式支持 */
@media (prefers-color-scheme: dark) {
  .cases-page {
    background-color: #000;
  }
}
